package com.slz3.business.module.templateExample.temStyle1.steward;

import com.slz3.business.frame.response.RR;
import com.slz3.business.frame.response.ResInfo;
import com.slz3.business.module.templateExample.temStyle1.domain.TemStyle1;
import com.slz3.business.module.templateExample.temStyle1.domain.TemStyle1Condition;
import org.springframework.stereotype.Component;
import org.springframework.web.reactive.function.server.ServerRequest;
import org.springframework.web.reactive.function.server.ServerResponse;
import reactor.core.publisher.Mono;

public class TemStyle1ResAtomic extends TemStyle1ResExecutor {

    public Mono<ServerResponse> add_$TemStyle1UpdateLock(ServerRequest req, TemStyle1 temStyle1) {
        return TemStyle1ResSafeValid.add(req, temStyle1) ?
                RR.fail(req, ResInfo.builder().theme(RR.SAFE_VALID).build()) :
                super.add(req, temStyle1);
    }

    public Mono<ServerResponse> delete_$TemStyle1UpdateLock(ServerRequest req, TemStyle1Condition temStyle1Condition) {
        return TemStyle1ResSafeValid.delete(req, temStyle1Condition) ?
                RR.fail(req, ResInfo.builder().theme(RR.SAFE_VALID).build()) :
                super.delete(req);
    }

    public Mono<ServerResponse> modify_$TemStyle1UpdateLock(ServerRequest req, TemStyle1 temStyle1) {
        return TemStyle1ResSafeValid.modify(req, temStyle1) ?
                RR.fail(req, ResInfo.builder().theme(RR.SAFE_VALID).build()) :
                super.modify(req, temStyle1);
    }

    public Mono<ServerResponse> info_$TemStyle1UpdateLock(ServerRequest req) {
        return TemStyle1ResSafeValid.info(req) ?
                RR.fail(req, ResInfo.builder().theme(RR.SAFE_VALID).build()) :
                super.info(req);
    }

    public Mono<ServerResponse> auditSubmit_$TemStyle1UpdateLock(ServerRequest req, TemStyle1Condition temStyle1Condition) {
        return TemStyle1ResSafeValid.auditSubmit(req, temStyle1Condition) ?
                RR.fail(req, ResInfo.builder().theme(RR.SAFE_VALID).build()) :
                super.auditSubmit(req);
    }

    public Mono<ServerResponse> audit_$TemStyle1UpdateLock(ServerRequest req, TemStyle1Condition temStyle1Condition) {
        return TemStyle1ResSafeValid.audit(req, temStyle1Condition) ?
                RR.fail(req, ResInfo.builder().theme(RR.SAFE_VALID).build()) :
                super.audit(req);
    }

    public Mono<ServerResponse> auditReject_$TemStyle1UpdateLock(ServerRequest req, TemStyle1Condition temStyle1Condition) {
        return TemStyle1ResSafeValid.auditReject(req, temStyle1Condition) ?
                RR.fail(req, ResInfo.builder().theme(RR.SAFE_VALID).build()) :
                super.auditReject(req);
    }


    public Mono<ServerResponse> usingEnable_$TemStyle1UpdateLock(ServerRequest req, TemStyle1Condition temStyle1Condition) {
        return TemStyle1ResSafeValid.usingEnable(req, temStyle1Condition) ?
                RR.fail(req, ResInfo.builder().theme(RR.SAFE_VALID).build()) :
                super.usingEnable(req);
    }

    public Mono<ServerResponse> usingDisable_$TemStyle1UpdateLock(ServerRequest req, TemStyle1Condition temStyle1Condition) {
        return TemStyle1ResSafeValid.usingDisable(req, temStyle1Condition) ?
                RR.fail(req, ResInfo.builder().theme(RR.SAFE_VALID).build()) :
                super.usingDisable(req);
    }
}
